function passwordCheck() {
    var userName = document.getElementsByName("userName")[0].value;
    var userNick = document.getElementsByName("userNick")[0].value;
    var userPassword = document.getElementsByName("password")[0].value;
    var userPassword2 = document.getElementsByName("userPassword2")[0].value;
    var tel = document.getElementsByName("userPhone")[0].value;
    const check = /^[a-zA-Z0-9]{6,16}$/;
    if (userName == null) {
        alert("用户名不能为空！");
        return false;
    }
    if (userNick == null) {
        alert("姓名不能为空！");
        return false;
    }
    if (!check.test(password)) {
        alert("密码必须是6到16位的字母或数字组合！");
        return false;
    }
    if (userPassword !== userPassword2) {
        alert("密码不一致！");
        return false;
    }
    if (tel.length !== 11) {
        alert("请输入正确的手机号码！");
        return false;
    }
    return true;
}